package com.fenghen.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.fenghen.system.mapper.RiskIdentificationMapper;
import com.fenghen.system.domain.RiskIdentification;
import com.fenghen.system.service.IRiskIdentificationService;
import com.fenghen.common.core.text.Convert;

/**
 * 风险识别模块Service业务层处理
 * 
 * @author fenghen
 * @date 2024-11-06
 */
@Service
public class RiskIdentificationServiceImpl implements IRiskIdentificationService 
{
    @Autowired
    private RiskIdentificationMapper riskIdentificationMapper;

    /**
     * 查询风险识别模块
     * 
     * @param riskId 风险识别模块主键
     * @return 风险识别模块
     */
    @Override
    public RiskIdentification selectRiskIdentificationByRiskId(Long riskId)
    {
        return riskIdentificationMapper.selectRiskIdentificationByRiskId(riskId);
    }

    /**
     * 查询风险识别模块列表
     * 
     * @param riskIdentification 风险识别模块
     * @return 风险识别模块
     */
    @Override
    public List<RiskIdentification> selectRiskIdentificationList(RiskIdentification riskIdentification)
    {
        return riskIdentificationMapper.selectRiskIdentificationList(riskIdentification);
    }

    /**
     * 新增风险识别模块
     * 
     * @param riskIdentification 风险识别模块
     * @return 结果
     */
    @Override
    public int insertRiskIdentification(RiskIdentification riskIdentification)
    {
        return riskIdentificationMapper.insertRiskIdentification(riskIdentification);
    }

    /**
     * 修改风险识别模块
     * 
     * @param riskIdentification 风险识别模块
     * @return 结果
     */
    @Override
    public int updateRiskIdentification(RiskIdentification riskIdentification)
    {
        return riskIdentificationMapper.updateRiskIdentification(riskIdentification);
    }

    /**
     * 批量删除风险识别模块
     * 
     * @param riskIds 需要删除的风险识别模块主键
     * @return 结果
     */
    @Override
    public int deleteRiskIdentificationByRiskIds(String riskIds)
    {
        return riskIdentificationMapper.deleteRiskIdentificationByRiskIds(Convert.toStrArray(riskIds));
    }

    /**
     * 删除风险识别模块信息
     * 
     * @param riskId 风险识别模块主键
     * @return 结果
     */
    @Override
    public int deleteRiskIdentificationByRiskId(Long riskId)
    {
        return riskIdentificationMapper.deleteRiskIdentificationByRiskId(riskId);
    }
}
